rm(list = ls())

## packages 

library(tidyverse)
library(fixest)

## Load data + dictionary 

dat <- readRDS('data/civey_clean.rds') 

m1 <- feols(vote_afd ~ treated_post | user_id + date, 
            data = dat %>% filter(!is.na(foreign_non_eu_share_2018_bin)),
            fsplit = ~ foreign_non_eu_share_2018_bin, 
            cluster = ~ user_id) 

etable(list(m1))

